package com.cornergj.model;

import org.springframework.format.annotation.DateTimeFormat;

public class OrderService implements Entity {
	
	private static final long serialVersionUID = 1L;
	
	/** ID */
	protected Integer id;
	
	/** 是否已经安排服务 */
	protected Integer arrange;
	
	/** 安排的保姆id */
	protected Integer arrangeNannyId;
	
	/** 联系方式 */
	protected String contactMethod;
	
	/** 联系人 */
	protected String contacts;
	
	/** 花费费用 */
	protected Double cost;
	
	/** 创建时间 */
	protected java.util.Date createTime;
	
	/** 订单id */
	protected String orderCode;
	
	/** 是否已经支付 */
	protected Integer pay;
	
	/** 备注信息 */
	protected String remarks;
	
	/** 城市id */
	protected Integer servicCity;
	
	/** 服务地址 */
	protected String serviceAddress;
	
	/** 服务周期 */
	protected Integer serviceCycle;
	
	/** 对应的serviceid */
	protected Integer serviceId;
	
	/** 省份id */
	protected Integer serviceProvince;
	
	/** 服务时间 */
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	protected java.util.Date serviceTime;
	
	/** 用户id */
	protected Integer userId;
	
 	public Integer getId() {
		return id;
	}
	
	public void setId(Integer id) {
		this.id = id;
	}
	
	public Integer getArrange() {
		return arrange;
	}
	
	public void setArrange(Integer arrange) {
		this.arrange = arrange;
	}
	
	public Integer getArrangeNannyId() {
		return arrangeNannyId;
	}
	
	public void setArrangeNannyId(Integer arrangeNannyId) {
		this.arrangeNannyId = arrangeNannyId;
	}
	
	public String getContactMethod() {
		return contactMethod;
	}
	
	public void setContactMethod(String contactMethod) {
		this.contactMethod = contactMethod;
	}
	
	public String getContacts() {
		return contacts;
	}
	
	public void setContacts(String contacts) {
		this.contacts = contacts;
	}
	
	public Double getCost() {
		return cost;
	}
	
	public void setCost(Double cost) {
		this.cost = cost;
	}
	
	public java.util.Date getCreateTime() {
		return createTime;
	}
	
	public void setCreateTime(java.util.Date createTime) {
		this.createTime = createTime;
	}
	
	public String getOrderCode() {
		return orderCode;
	}
	
	public void setOrderCode(String orderCode) {
		this.orderCode = orderCode;
	}
	
	public Integer getPay() {
		return pay;
	}
	
	public void setPay(Integer pay) {
		this.pay = pay;
	}
	
	public String getRemarks() {
		return remarks;
	}
	
	public void setRemarks(String remarks) {
		this.remarks = remarks;
	}
	
	public Integer getServicCity() {
		return servicCity;
	}
	
	public void setServicCity(Integer servicCity) {
		this.servicCity = servicCity;
	}
	
	public String getServiceAddress() {
		return serviceAddress;
	}
	
	public void setServiceAddress(String serviceAddress) {
		this.serviceAddress = serviceAddress;
	}
	
	public Integer getServiceCycle() {
		return serviceCycle;
	}
	
	public void setServiceCycle(Integer serviceCycle) {
		this.serviceCycle = serviceCycle;
	}
	
	public Integer getServiceId() {
		return serviceId;
	}
	
	public void setServiceId(Integer serviceId) {
		this.serviceId = serviceId;
	}
	
	public Integer getServiceProvince() {
		return serviceProvince;
	}
	
	public void setServiceProvince(Integer serviceProvince) {
		this.serviceProvince = serviceProvince;
	}
	
	public java.util.Date getServiceTime() {
		return serviceTime;
	}
	
	public void setServiceTime(java.util.Date serviceTime) {
		this.serviceTime = serviceTime;
	}
	
	public Integer getUserId() {
		return userId;
	}
	
	public void setUserId(Integer userId) {
		this.userId = userId;
	}
	
 	@Override
	public String toString() {
		StringBuilder builder = new StringBuilder();
		builder.append("id = ").append(id).append(", ");
		builder.append("arrange = ").append(arrange).append(", ");
		builder.append("arrangeNannyId = ").append(arrangeNannyId).append(", ");
		builder.append("contactMethod = ").append(contactMethod).append(", ");
		builder.append("contacts = ").append(contacts).append(", ");
		builder.append("cost = ").append(cost).append(", ");
		builder.append("createTime = ").append(createTime).append(", ");
		builder.append("orderCode = ").append(orderCode).append(", ");
		builder.append("pay = ").append(pay).append(", ");
		builder.append("remarks = ").append(remarks).append(", ");
		builder.append("servicCity = ").append(servicCity).append(", ");
		builder.append("serviceAddress = ").append(serviceAddress).append(", ");
		builder.append("serviceCycle = ").append(serviceCycle).append(", ");
		builder.append("serviceId = ").append(serviceId).append(", ");
		builder.append("serviceProvince = ").append(serviceProvince).append(", ");
		builder.append("serviceTime = ").append(serviceTime).append(", ");
		builder.append("userId = ").append(userId);
		return builder.toString();
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((id == null) ? 0 : id.hashCode());
		return result;
	}
	
	@Override
	public boolean equals(Object obj) {
		if (this == obj) {
			return true;
		}
		if (obj == null) {
			return false;
		}
		if (getClass() != obj.getClass()) {
			return false;
		}
		OrderService other = (OrderService) obj;
		if (id == null) {
			if (other.id != null) {
				return false;
			}
		} else if (!id.equals(other.id)) {
			return false;
		}
		return true;
	}

}